
import time
import threading
import os

timestamp = time.time()
lockTimestamp = threading.Lock()

if not os.path.exists(os.getcwd() + '/logs/'):
    os.makedirs(os.getcwd() + '/logs/')

logFile = open(os.getcwd() + '/logs/' + str(time.asctime().replace(' ', '_')), 'w')

##print logFile

alarmCount = 0
alarmRead = 0
alarmUpload = 0

TempReadings = ()
lockTemp = threading.Lock()

LightReadings = ()
lockLight = threading.Lock()

PirReadings = ()
lockPir = threading.Lock()

POST_buffer = ''
